home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Family Forum 255
/
SOMC Family Forum 255.iso
/
somc
/
BBucket.dir
/
00002_Script_2
< prev
next >
Wrap
Text File
|
1998-09-14
|
2KB
|
69 lines
on enterframe
global redo
if redo then
reset()
set redo to FALSE
end if
end
on exitframe
global score,castpic,Vspeed,level,lives,lastspeed,SPEEDUP
-- move sprite
set the locV of sprite 6 to (the locV of sprite 6 + (Vspeed * level))
updateStage
if (the locV of sprite 6 > 320) then -- check if at the bottom
set the visible of sprite 6 to FALSE
if not(Vspeed = SPEEDUP) then -- check that the down arrow was not used
upscore()
end if
if Vspeed = SPEEDUP then
set Vspeed to lastspeed --reset the speed back
end if
set castpic to (random (5) + 12) -- get new falling object
set the memberNum of sprite 6 to castpic
set the locV of sprite 6 to 18
set the locH of sprite 6 to 320
updateStage
set the visible of sprite 6 to TRUE
end if
go to the frame
end
on keyDown
global Vspeed,castpic,lastspeed,SPEEDUP
set ARROW to the keycode
case ARROW of
125:-- down arrow
set lastspeed to Vspeed -- save speed
set Vspeed to SPEEDUP
repeat while (the locV of sprite 6 < 250)
set the locV of sprite 6 to (the locV of sprite 6 + Vspeed )
updateStage
end repeat
upscore()
123:--left arrow
set the locH of sprite 6 to (the locH of sprite 6 - 130)
if the locH of sprite 6 < 80 then
set the locH of sprite 6 to 70
-- beep
end if
124:-- right arrow
set the locH of sprite 6 to (the locH of sprite 6 + 130)
if the locH of sprite 6 > 570 then
set the locH of sprite 6 to 570
-- beep
end if
12:
quit
otherwise:
beep
end case
updateStage
end keyDown